package tmp;

// Generated 04-nov-2009 18:40:40 by Hibernate Tools 3.2.4.GA

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

/**
 * ServiceOption generated by hbm2java
 */
@Entity
@Table(name = "service_option", catalog = "fmanzano_gem", uniqueConstraints = {
		@UniqueConstraint(columnNames = "SEO_NAME"),
		@UniqueConstraint(columnNames = "SEO_URL"),
		@UniqueConstraint(columnNames = { "SER_ID", "SEO_ID" }) })
public class ServiceOption implements java.io.Serializable {

	private Integer seoId;
	private Service service;
	private String seoName;
	private String seoUrl;

	public ServiceOption() {
	}

	public ServiceOption(Service service, String seoName) {
		this.service = service;
		this.seoName = seoName;
	}

	public ServiceOption(Service service, String seoName, String seoUrl) {
		this.service = service;
		this.seoName = seoName;
		this.seoUrl = seoUrl;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "SEO_ID", unique = true, nullable = false)
	public Integer getSeoId() {
		return this.seoId;
	}

	public void setSeoId(Integer seoId) {
		this.seoId = seoId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "SER_ID", nullable = false)
	public Service getService() {
		return this.service;
	}

	public void setService(Service service) {
		this.service = service;
	}

	@Column(name = "SEO_NAME", unique = true, nullable = false, length = 30)
	public String getSeoName() {
		return this.seoName;
	}

	public void setSeoName(String seoName) {
		this.seoName = seoName;
	}

	@Column(name = "SEO_URL", unique = true, length = 200)
	public String getSeoUrl() {
		return this.seoUrl;
	}

	public void setSeoUrl(String seoUrl) {
		this.seoUrl = seoUrl;
	}

}
